  <meta charset="UTF-8" />
    <link href="<?php echo base_url()."assets/css/bootstrap.css";?>" rel="stylesheet" type="text/css"/>
  <link href="<?php echo base_url()."assets/css/custom/menu.css";?>" rel="stylesheet" type="text/css"/>
  <script src="<?php echo base_url()."assets/js/jquery-2.1.1.js";?>"></script>
  <script src="<?php echo base_url()."assets/js/custom/menu.js";?>"></script>
  <script src="<?php echo base_url()."assets/js/custom/main.js";?>"></script>
  <body>
  <?php
    //echo base_url();

    if ($language==="vi") {
      echo $this->dynamic_menuvi->build_menu();
      // var_dump("viet vam");
    }

    if ($language==="en" || $language===null) {
      echo $this->dynamic_menu->build_menu();
    }

?>

<!-- change language -->
<div id="langselect" style="float:right;margin-top:-35px;position:relative">
  <!-- The second value will be selected initially -->
  <b style="color:#FFFFFF">Choose Language</b>
  <select name="select_language" id= "slelect_language">
  <?php
    if ($language==="vi") {
      echo '<option value="vi" selected>Tiếng Việt</option> ';
      echo '<option value="en">English</option>';
    }

    if ($language==="en" || $language===null) {
      echo '<option value="vi">Tiếng Việt</option> ';
      echo '<option value="en" selected>English</option>';
    }
  ?>
  </select>
</div>
<!-- end change language -->
  <div id="infoMessage"><?php echo $message;?></div>
<div>
  <br />
</div>
  <table cellpadding=0 cellspacing=10 class="table">
  	<tr>
  		<th><?php echo lang('index_fname_th');?></th>
  		<th><?php echo lang('index_lname_th');?></th>
  		<th><?php echo lang('index_email_th');?></th>
  		<th><?php echo lang('index_groups_th');?></th>
  		<th><?php echo lang('index_status_th');?></th>
  		<th><?php echo lang('index_action_th');?></th>
  	</tr>
  	<?php foreach ($users as $user):?>
  	<tr>
  		<td><?php echo htmlspecialchars($user->first_name,ENT_QUOTES,'UTF-8');?></td>
  		<td><?php echo htmlspecialchars($user->last_name,ENT_QUOTES,'UTF-8');?></td>
  		<td><?php echo htmlspecialchars($user->email,ENT_QUOTES,'UTF-8');?></td>
  		<td>
  			<?php foreach ($user->groups as $group):?>
  			<?php echo anchor("auth/edit_group/".$group->id, htmlspecialchars($group->name,ENT_QUOTES,'UTF-8')) ;?><br />
  		<?php endforeach?>
  	</td>
  	<td><?php echo ($user->active) ? anchor("auth/deactivate/".$user->id, lang('index_active_link')) : anchor("auth/activate/". $user->id, lang('index_inactive_link'));?></td>
  	<td><?php echo anchor("auth/edit_user/".$user->id, 'Edit') ;?></td>
  </tr>
<?php endforeach;?>
</table>

<p><?php echo anchor('auth/create_user', lang('index_create_user_link'))?> | <?php echo anchor('auth/create_group', lang('index_create_group_link'))?>| <?php echo anchor('auth/logout', 'Logout')?></p>
<div style="visibility: hidden">
 <br />
 <a href="http://apycom.com/">Apycom jQuery Menus</a><br />
 </div>
<div>
     <input type="submit" value="Submit" id="submit">
</div>

</body>